package com.etc.entity;

import java.util.Date;

public class User {
    private Integer userid;

    private String username;

    private String userpwd;

    private String email;

    private String sex;

    private String birthday;

    private String tel;

    private Integer level;

    private Integer status;
    private String udate;
    public String getUdate() {
		return udate;
	}

	public void setUdate(String udate) {
		this.udate = udate;
	}

	{
    	this.udate=new Date().toLocaleString();//每创建一个新用户就自动填写时间
    }
    public User(String username, String userpwd, String email, String sex, String birthday, String tel, Integer level,
			Integer status) {
		super();
		this.username = username;
		this.userpwd = userpwd;
		this.email = email;
		this.sex = sex;
		this.birthday = birthday;
		this.tel = tel;
		this.level = level;
		this.status = status;
	}

	@Override
	public String toString() {
		return "User [userid=" + userid + ", username=" + username + ", userpwd=" + userpwd + ", email=" + email
				+ ", sex=" + sex + ", birthday=" + birthday + ", tel=" + tel + ", level=" + level + ", status=" + status
				+ ", udate=" + udate + "]";
	}

	public User() {
		super();
	}

	public User(Integer userid, String username, String userpwd, String email, String sex, String birthday, String tel,
			Integer level, Integer status) {
		super();
		this.userid = userid;
		this.username = username;
		this.userpwd = userpwd;
		this.email = email;
		this.sex = sex;
		this.birthday = birthday;
		this.tel = tel;
		this.level = level;
		this.status = status;
	}

//	@Override
//	public String toString() {
//		return "User [userid=" + userid + ", username=" + username + ", userpwd=" + userpwd + ", email=" + email
//				+ ", sex=" + sex + ", birthday=" + birthday + ", tel=" + tel + ", level=" + level + ", status=" + status
//				+ "]";
//	}

	public Integer getUserid() {
        return userid;
    }

    public void setUserid(Integer userid) {
        this.userid = userid;
    }

    public String getUsername() {
        return username;
    }

    public void setUsername(String username) {
        this.username = username == null ? null : username.trim();
    }

    public String getUserpwd() {
        return userpwd;
    }

    public void setUserpwd(String userpwd) {
        this.userpwd = userpwd == null ? null : userpwd.trim();
    }

    public String getEmail() {
        return email;
    }

    public void setEmail(String email) {
        this.email = email == null ? null : email.trim();
    }

    public String getSex() {
        return sex;
    }

    public void setSex(String sex) {
        this.sex = sex == null ? null : sex.trim();
    }

    public String getBirthday() {
        return birthday;
    }

    public void setBirthday(String birthday) {
        this.birthday = birthday == null ? null : birthday.trim();
    }

    public String getTel() {
        return tel;
    }

    public void setTel(String tel) {
        this.tel = tel == null ? null : tel.trim();
    }

    public Integer getLevel() {
        return level;
    }

    public void setLevel(Integer level) {
        this.level = level;
    }

    public Integer getStatus() {
        return status;
    }

    public void setStatus(Integer status) {
        this.status = status;
    }
}